nestedsvm: reduce TLB flushes
authorKeir Fraser <keir@xen.org>
Fri, 20 May 2011 08:07:54 +0000 (09:07 +0100)
committerKeir Fraser <keir@xen.org>
Fri, 20 May 2011 08:07:54 +0000 (09:07 +0100)
commitc33a0b24c1f04d45d79c0b5657ecb25677dd1fb2
treefd388a920a3c672d794fc2ee8bdf77259eecbb37
parent2be3bcbfe84713c49a42041baf3451e20a381355
nestedsvm: reduce TLB flushes

Reduce TLB flushes:
1. When we update the cr3 during VMRUN/VMEXIT emulation
    we toggle between n1asid and n2asid forth and back
    => no TLB flush needed
2. Only flush n1asid or n2asid depending on vcpu guest mode
    and not both unconditionally.

Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Signed-off-by: Keir Fraser <keir@xen.org>
xen/arch/x86/hvm/svm/svm.c